import request from "@/utils/request";

// 新增日常验房验房记录
export function addRoutineInspection(data) {
  return request({
    url: "/enterprise/house/inspection/routineInspection",
    method: "post",
    data: data,
  });
}

// 新增换退验房记录  （房态新增验房）
export function addInspection(data) {
  return request({
    url: "/enterprise/house/inspection",
    method: "post",
    data: data,
  });
}

// 删除保洁人员信息（路径跟保洁人员id）
export function deleteInspection(id) {
  return request({
    url: "/enterprise/house/inspection/" + id,
    method: "delete",
  });
}

// 验房列表
export function listInspection(params) {
  return request({
    url: "/enterprise/house/inspection/list",
    method: "get",
    params: params,
  });
}

// 指定验房人员
export function assignInspection(data) {
  return request({
    url: "/enterprise/house/inspection",
    method: "put",
    data: data,
  });
}

// 更换验房人员
export function changeInspection(data) {
  return request({
    url: "/enterprise/house/inspection/change",
    method: "put",
    data: data,
  });
}

// 获取验房记录详细信息（路径后面验房id）
export function getInspection(id) {
  return request({
    url: "/enterprise/house/inspection/"+id,
    method: "get",
  });
}

// 查询验房人员信息
//查询打扫人员信息
export function getCleanerUserInfo(params) {
  return request({
    url: "/enterprise/cleaner/cleaner/cleanerUserInfo",
    method: "get",
    params: params,
  });
}

// 查询房间列表(包含配置状态：已配置、未配置)
export function listRoomWithConfig(query) {
  return request({
    url: '/enterprise/house/cleaningProcess/list',
    method: 'get',
    params: query,
  })
}
